package com.indusfo.spc.mapper;

import com.indusfo.spc.pojo.MatRepairFlow;
import com.indusfo.spc.pojo.OrderRepairFlow;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Author liub
 * @Date 2019/11/27 10:58
 * @Version 1.0
 */


public interface OrderRepairFlowMapper {
    /**
     * 新增
     */
    int insertOrderRepairFlow(OrderRepairFlow orderRepairFlow);

    /**
     * 修改
     */
    int updateOrderRepairFlow(OrderRepairFlow orderRepairFlow);

    /**
     * 查询
     */
    List<OrderRepairFlow> queryOrderRepairFlow(OrderRepairFlow orderRepairFlow);

    /**
     * 总数
     */
    int countOrderRepairFlow(OrderRepairFlow orderRepairFlow);

    /**
     * 判重
     */
    int checkOrderRepairFlow(OrderRepairFlow orderRepairFlow);

    /**
     * 启停
     */
    int deleteOrderRepairFlow(@Param("orderRepairFlowIds") List<Integer> orderRepairFlowIds, @Param("dataState") Integer dataState);

    /**
     * 级联删除查询
     */
    List<OrderRepairFlow> queryOrderRepairFlowByOrderRepairId(@Param("orderRepairId") Integer orderRepairId);

    /**
     * 级联删除
     */
    int deleteOrderRepairFlowByOrderRepairFlowId(@Param("orderRepairFlowId") Integer orderRepairFlowId, @Param("dataState") Integer dataState);

    int insertOrderRepairFlowByMatRepairFlow(@Param("matRepairFlowList") List<MatRepairFlow> matRepairFlowList);

}